'use strict';

import React, { Component, PropTypes } from 'react';
import ReactNative, { Text, View, StyleSheet, Platform, TouchableOpacity, TouchableNativeFeedback, ListView, Image, PixelRatio } from 'react-native';
import ListviewForOther from './ListViewForOther';
import px2dp from '../util/px2dp';
import theme from '../config/Theme';
import Swiper from 'react-native-swiper';

export default class ListViewForHome extends Component {

    render() {
        return (
            <View style={{ flex: 1 }}>
                <Swiper
                    height={px2dp(130)}
                    autoplay={true}
                    bounces={true}>
                    <View style={styles.slide}>
                        <Image style={styles.image} source={require('../image/test1.jpg')} resizeMode="stretch" />
                    </View>
                    <View style={styles.slide}>
                        <Image style={styles.image} source={require('../image/test2.jpg')} resizeMode="stretch" />
                    </View>
                    <View style={styles.slide}>
                        <Image style={styles.image} source={require('../image/test3.jpg')} resizeMode="stretch" />
                    </View>
                </Swiper>
                <ListviewForOther contents={this.props.contents} navigator={this.props.navigator}></ListviewForOther>
            </View>
        )
    }

}

const styles = StyleSheet.create({
    slide: {

    },
    image: {
        height: px2dp(130),
        width: theme.width
    },
});